<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>登录</title>
</head>
<body>
    <span th:if="${param.error}" style="color:red">
        账号或密码错误
    </span>
    <!--调用Security自带的登录接口login-->
    <form th:action="@{/doLogin}" method="post">
        <!--账号密码的name默认username和password-->
        <input type="text" name="username" placeholder="请输入账号"/><br>
        <input type="password" name="password" placeholder="请输入密码"/><br>
        <input type="checkbox" name="rememberMe" value="true">记住我<br>
        <input type="submit" value="登录">
    </form>
</body>
</html>